<template>
  <div class="dot">
    <md-button id="btn" type="primary" elementCode="A01" @click="clickMe()">click me</md-button>
    <md-input-item class="ipt" elementCode="A02" title="普通文本" placeholder="普通文本"></md-input-item>
    <md-button type="primary" @click="goHome()">goHome</md-button>
    <md-button type="primary" @click="goHome2()">goHome2</md-button>
    <md-button type="primary" @click="goHome3()">goHome3</md-button>
    <!-- <div @click="goHome2()" elementCode="A01">goHome2</div> -->
  </div>
</template>

<script>
  import {
    Button,
    InputItem
  } from 'mand-mobile'
  export default {
    name: 'dot',
    components: {
      'md-button': Button,
      'md-input-item': InputItem,
    },
    data() {
      return {
        day1: '',
        day2: ''
      }
    },
    methods: {
      testPage(data){
        console.log('我是dotdemo中的方法',data)
        data.remark = {
          name: '张三'
        }
      },
      clickMe() {
      },
      goHome() {
        this.$router.push('/faceDemo')
      },
      goHome2() {
        this.day1 = new Date().getTime()
      },
      goHome3() {
        this.day2 = new Date().getTime()
        let day3 = this.day2 - this.day1
        let day4 = Math.round(day3/1000)
        console.log(day3,day4)
      }
    }
  }
</script>

<style lang="less" scoped>
</style>
